/**
 *Copyright (c) 2003, 2018, UMF and/or its affiliates. All rights reserved.
 */
package com.umf.b2b.model.register;

import com.umf.b2b.MerchantBaseRequest;
import com.umpay.dto.UMFResponse.Message;
import com.umpay.util.UMFUtil;

/**
<p>Title:RegisterPersonal</p>  
<p>Description: �����̻�����</p>
 */
public class RegisterPersonal extends MerchantBaseRequest {

	private String notify_url;//�첽֪ͨ��ַ
	private String order_id;//*������[��Ӧ����]������Ψһ,�̻�ƽ̨�Լ����ɵĶ�����,֧������,Ӣ����ĸ
	private String mer_date;//*�������̻�ƽ̨���ɵĽ�������
	private String mer_cust_id;//*������[��Ӧ����],�̻�ƽ̨���ͻ������Ψһ���
	private String user_type = "1";//*����������̶�ֵ��1��1�������̻���
	private String mobile_id;//*��������ϵ���ֻ���
	private String cust_name;//*�������ͻ�����������CipherUtil.encrypt���ܱ���
	private String identity_type;//*������֤������ �̶�ֵ��1���������֤��
	private String identity_code;//*������֤���ţ�����CipherUtil.encrypt���ܱ���
	private String sub_mer_alias;//ҵ�����������������ƣ�ʹ��UTF-8����
	
	private String url = "/register/personal";//�������
	
	private String reg_date;//[��Ӧ����]��ע�����ڣ���������ƽ̨���صĿͻ�ע�����ڣ���ʽ��YYYYMMDD
	private String user_id;//[��Ӧ����]�����ɹ����������صĿͻ�Ψһ���

	@Override
	public String getRequestUrl() {
		return baseUrl + url;
	}

	@Override
	public RegisterPersonal doRequest() throws Exception {
		Message<RegisterPersonal> response = UMFUtil.post(createAPIContext(), this,RegisterPersonal.class);
		MerchantBaseRequest baseResult = convertResult(response, RegisterPersonal.class);
		if(baseResult == null)
			return null;
		return (RegisterPersonal)baseResult;
	}
	
	public String getMer_id() {
		return mer_id;
	}

	public void setMer_id(String mer_id) {
		this.mer_id = mer_id;
	}

	public String getOrder_id() {
		return order_id;
	}

	public void setOrder_id(String order_id) {
		this.order_id = order_id;
	}

	public String getMer_date() {
		return mer_date;
	}

	public void setMer_date(String mer_date) {
		this.mer_date = mer_date;
	}

	public String getMer_cust_id() {
		return mer_cust_id;
	}

	public void setMer_cust_id(String mer_cust_id) {
		this.mer_cust_id = mer_cust_id;
	}

	public String getUser_type() {
		return user_type;
	}

	public void setUser_type(String user_type) {
		this.user_type = user_type;
	}

	public String getCust_name() throws Exception {
		return cust_name;
	}

	public void setCust_name(String cust_name) {
		this.cust_name = cust_name;
	}

	public String getIdentity_type() {
		return identity_type;
	}

	public void setIdentity_type(String identity_type) {
		this.identity_type = identity_type;
	}

	public String getIdentity_code() throws Exception {
		return identity_code;
	}

	public void setIdentity_code(String identity_code) {
		this.identity_code = identity_code;
	}

	public String getMobile_id() {
		return mobile_id;
	}

	public void setMobile_id(String mobile_id) {
		this.mobile_id = mobile_id;
	}

	public String getNotify_url() {
		return notify_url;
	}

	public void setNotify_url(String notify_url) {
		this.notify_url = notify_url;
	}

	public String getReg_date() {
		return reg_date;
	}

	public void setReg_date(String reg_date) {
		this.reg_date = reg_date;
	}

	public String getUser_id() {
		return user_id;
	}

	public void setUser_id(String user_id) {
		this.user_id = user_id;
	}

	public String getSub_mer_alias() {
		return sub_mer_alias;
	}

	public void setSub_mer_alias(String sub_mer_alias) {
		this.sub_mer_alias = sub_mer_alias;
	}

	@Override
	public String toString() {
		StringBuilder builder = new StringBuilder();
		builder.append("RegisterPersonal [notify_url=");
		builder.append(notify_url);
		builder.append(", order_id=");
		builder.append(order_id);
		builder.append(", mer_date=");
		builder.append(mer_date);
		builder.append(", mer_cust_id=");
		builder.append(mer_cust_id);
		builder.append(", user_type=");
		builder.append(user_type);
		builder.append(", mobile_id=");
		builder.append(mobile_id);
		builder.append(", cust_name=");
		builder.append(cust_name);
		builder.append(", identity_type=");
		builder.append(identity_type);
		builder.append(", identity_code=");
		builder.append(identity_code);
		builder.append(", sub_mer_alias=");
		builder.append(sub_mer_alias);
		builder.append(", url=");
		builder.append(url);
		builder.append(", reg_date=");
		builder.append(reg_date);
		builder.append(", user_id=");
		builder.append(user_id);
		builder.append(", version=");
		builder.append(version);
		builder.append(", mer_id=");
		builder.append(mer_id);
		builder.append(", ret_code=");
		builder.append(ret_code);
		builder.append(", ret_msg=");
		builder.append(ret_msg);
		builder.append(", links=");
		builder.append(links);
		builder.append("]");
		return builder.toString();
	}

}
